home *** CD-ROM | disk | FTP | other *** search
/ Turnbull China Bikeride / Turnbull China Bikeride - Disc 1.iso / ARGONET / PD / PROGRAMMING / DESKLIBC / SOURCES.ZIP / DeskLib / !DLSources / Libraries / Menu / c / SetFlags < prev    next >
Text File  |  1995-07-09  |  1KB  |  29 lines

  1. /*
  2.     ####             #    #     # #
  3.     #   #            #    #       #          The FreeWare C library for 
  4.     #   #  ##   ###  #  # #     # ###             RISC OS machines
  5.     #   # #  # #     # #  #     # #  #   ___________________________________
  6.     #   # ####  ###  ##   #     # #  #                                      
  7.     #   # #        # # #  #     # #  #    Please refer to the accompanying
  8.     ####   ### ####  #  # ##### # ###    documentation for conditions of use
  9.     ________________________________________________________________________
  10.  
  11.     File:    Menu.SetFlags.c
  12.     Author:  Copyright © 1993 Shaun Blackmore and Jason Williams
  13.     Version: 1.00 (30 Apr 1993)
  14.     Purpose: Sets ticked/shaded flags for a menu item
  15. */
  16.  
  17. #include "DeskLib:Wimp.h"
  18. #include "DeskLib:Menu.h"
  19.  
  20.  
  21. void Menu_SetFlags(menu_ptr menu, int entry, int ticked, int shaded)
  22. {
  23.   menu_item *item = (menu_item *) (((int) menu) + sizeof(menu_block));
  24.  
  25.   item = &item[entry];
  26.   item->menuflags.data.ticked = ticked;
  27.   item->iconflags.data.shaded = shaded; 
  28. }
  29.